	--温馨提示varchar2长度默认为50,请自行修改
	create table ${tableName}(
	     <#list columns as column>
	     	${column.name} <#if column.jdbcType=='VARCHAR'>${column.jdbcType}(${varcharLength})<#elseif column.jdbcType=='NUMERIC'>number(20,2)<#else>${column.jdbcType}</#if> <#if column.name=='id'>primary key AUTO_INCREMENT</#if><#if column_index+1!=columns?size>,</#if>
	     </#list>
	);
	
	<resultMap id="defaultResultMap" type="${parameterType}" >
	     <#list columns as column>
		     <result property="${column.alias}" column="${column.name}" />
	     </#list>
	</resultMap>
	
	<insert id="insert" parameterType="${parameterType}">
		insert into ${tableName}(
	        <#list columns as column>
		    ${column.name}<#if (columns?size !=(column_index+1) ) >,</#if>
	        </#list>
		)
		VALUES(
		   <#list columns as column>
		    #\{${column.value},jdbcType=${column.jdbcType}\}<#if (columns?size !=(column_index+1) ) >,</#if>
		   </#list>
		)    
	</insert>

	<update id="update" parameterType="${parameterType}">
		update ${tableName}
		<set>
		  <#list columns as column>
		    <if test="${column.condition}">${column.name}=#\{${column.value}\},</if>
		  </#list>
		</set>
		where fid=#\{id\}
	</update>

	<delete id="delete" parameterType="map">
		delete 
		from 
		   ${tableName}
		where 
		fid=#\{id\}
	</delete>
	
	<select id="selectByMap" parameterType="map" resultType="${parameterType}">
		select 
	       <#list columns as column>
		    ${column.name}					"${column.alias}"<#if (columns?size !=(column_index+1) ) >,</#if>                                 
		   </#list>
		from 
		   ${tableName}
		where  1=1
		   <if test="id !=null">
		    and fid=#\{id\}
		   </if>
	</select>